interface RequestList {
  id: string;
  name: string;
}
interface Domain {
  event: string;
  text: string;
}

export const domainData = [
  { id: '', name: '云应用平台' },
  { id: 'BZ', name: '航空港报装系统' },
  { id: 'DA', name: '档案系统' },
  { id: 'DEV', name: '平台开发库' },
  { id: 'GIS', name: 'GIS开发库' },
  { id: 'OA', name: '办公系统' },
  { id: 'HR', name: '人力资源' },
  { id: 'XT', name: '湘潭第三水厂' },
  { id: 'XCSW', name: '宣城水务报装系统' },
  { id: 'GXGS', name: '高新水报装系统' },
  { id: 'HSTZ', name: '环水投资管理系统' },
  { id: 'GDCY', name: '广东辰宜办公系统' },
  { id: 'BJ', name: '布吉水务平台' },
  { id: 'RQBZ', name: '燃气企业报装系统' },
  { id: 'HACCP', name: '优质应用水管控系统' },
  { id: 'BW', name: '表务系统' },
  { id: 'OADev', name: '办公系统开发版本' },
  { id: 'PSJC', name: '集团排水监测' },
  { id: 'JYTOA', name: '金源泰办公系统' },
];

export const getDomainList = (list: RequestList[]): Domain[] => {
  const tempArr: Domain[] = [];
  list.map((item) => {
    tempArr.push({
      event: item.id,
      text: item.name,
    });
  });
  return tempArr;
};
